/*************************************************************************
	> File Name: P2415.cpp
	> Author: yufangze
	> Mail: 2224590123@qq.com
	> Created Time: 2025-01-09 16:28:23
 ************************************************************************/

#include <iostream>
#include <set>
#include <map>
#include <vector>
#include <algorithm>
#include <cmath>
using namespace std;

int a[31], k = 0;

int main() {
    long long ans = 0;
    while (cin >> a[k++]);
    for (int i = 0; i < k; i++) {
        ans += a[i];
    }
    ans *= pow(2, k - 2);
    cout << ans << endl;
    return 0;
}
